package ch03.staticdaili;

import java.lang.reflect.Proxy;

public class DaiLi {
   private static Object piao=new HuoCheZhan();
    public static ShouPiao daiLi(){
       return (ShouPiao) Proxy.newProxyInstance(
                piao.getClass().getClassLoader(),
                piao.getClass().getInterfaces(),
                new DaiLiShiXian(piao)
        );
    }
}
